using UnityEngine;
using System.Collections;

public class EarthScript : MonoBehaviour {

	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
	
	}
	
	void OnTriggerEnter ( Collider other) {
    Debug.Log("Collision");
}
	
	void OnTriggerStay( Collider other ) 
	{
		Vector3 delta = transform.position - other.transform.position;
		other.rigidbody.AddForce(delta*5);
	}
}
